Skip to content

Conversation

bhouston
Copy link
Member

Description

This PR fixes a bug in shellStart where the shellId returned from ShellTracker.registerShell() was not being used when updating the shell status, causing short-lived shell commands to remain in the "running" state even after they completed.

Changes

  • Fixed shellStart.ts to use the shellId returned from registerShell() instead of generating a new one
  • Added a test file to verify the fix

Related Issues

Fixes #379

Testing

  • Added a new test file specifically to verify the fix
  • Ran existing ShellTracker tests to ensure they still pass
  • Created a manual verification script to confirm the behavior is correct

Notes

This was a subtle bug where shellStart was generating a UUID with uuidv4() but not using that ID when registering the shell. Instead, ShellTracker.registerShell() was generating its own UUID. When the shell status was later updated, it was using the first UUID, which wasn't associated with any registered shell.

@bhouston bhouston merged commit ba58abb into main Mar 25, 2025
0 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: ShellTracker incorrectly reports short-lived commands as still running
1 participant